package mes.kanban.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import mes.kanban.respository.RedisRespositoryI;
import mes.kanban.service.RedisServiceI;
import redis.clients.jedis.Jedis;

@Service
public class RedisServiceImpl implements RedisServiceI {
	
	@Autowired
	private RedisRespositoryI redisdao;

	@Override
	public String getConfig(String key) {
		return redisdao.getValue(key);
	}

	@Override
	public void setConfig(String key, String value) {
		redisdao.setValue(key, value);
	}

	@Override
	public void hashSetValue(String hashkey, String key, String value) {
		redisdao.hset(hashkey, key, value);
	}

	@Override
	public String hashGetValue(String hashKey, String key) {
		return redisdao.hget(hashKey, key);
	}

	@Override
	public Jedis jedis() {
		return redisdao.getjedis();
	}
	
	

}
